<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 
<script type="text/javascript" src='js/jquery.js'></script>
<script type='text/javascript'>
$(document).ready(function()
{
$('#UpdateButton').click(function()
{
	var MSG = $("#name").val();
	var dataString = 'name='+ MSG;
//	var MSG2 = $("#alamat").val();
//	var dataString2 = 'alamat='+ MSG2;
	$.ajax({
		type: "POST",
		url: "insertname",
		data: dataString,
		//data: dataString2,
		cache: false,
		success: function(data)
		{
			$("#name").val('');
			//$("#alamat").val('');
			$("#content").prepend(data);
			$("#name").focus();
		}
	});
	return false;
	});
});
</script> 
<!-- <form action="/cobapertama/insertname" method="post" onSubmit="return validateInputs()">  -->
<textarea id='name'></textarea><br/>
<!-- <textarea id='alamat'></textarea><br/> -->
<input type="button" value='Insert' id='UpdateButton'/>
<div id='content'></div>
<!-- </form>  -->

